package com.me.study.designPatterns.bDecorator;

/**
 * 装饰器模式：装饰类--最帅的<p>
 *     TODO 为什么实现类要加相同的构造函数？因为编译不通过 there is no default constructor available in '**.Class'
 *      因为不加会默认生成空参构造，而子类构造默认会调用父类的构造，父类却没有空参构造
 *
 * @author ME
 * @date   2019/4/4
 */
public class HandsomeDecorator extends AbstractDecortor {

    public HandsomeDecorator(Someone someone) {
        super(someone);
    }

    @Override
    public void say() {
        super.say();
        this.sayHandsome();
    }

    private void sayHandsome() {
        System.out.println("我是最帅的！");
    }
}
